package Slides
{
	import flash.events.MouseEvent;
	
	import mx.containers.Canvas;
	import mx.controls.TextArea;
	
	public class TextCnvs extends Canvas
	{
		private var txt :TextArea;
		
		public function TextCnvs()
		{
			this.height=50;
			this.width=100;
			this.alpha=0;
			this.setStyle("borderStyle","solid");
			this.addEventListener(MouseEvent.MOUSE_DOWN,strtDrag);
			this.addEventListener(MouseEvent.MOUSE_UP,stpDrag);
			
			this.txt=new TextArea;
			txt.x=0;
			txt.y=5;
			txt.height=45;
			txt.width=100;
			txt.editable=true;
			txt.enabled=true;
			txt.text="Type your Text Here"
			this.addChild(this.txt);
			
			
		}
		
		private function strtDrag(event : MouseEvent):void{
			if(this.contentMouseY<5)
			event.currentTarget.startDrag();
		}
		
		private function stpDrag(event:MouseEvent):void{
			event.currentTarget.stopDrag();
		}

	}
}